class UserEntity {
  final String id;
  String name;
  String avatar;

  UserEntity(this.id, this.name, this.avatar);

  factory UserEntity.fromJson(Map<String, dynamic> jsonRes) {
    return UserEntity(jsonRes["id"], jsonRes["name"], jsonRes["avatar"]);
  }

  Map<String, dynamic> toJson() {
    return {"id": id, "name": name, "avatar": avatar};
  }

  @override
  String toString() {
    return 'UserEntity:${toJson()}';
  }
}
